﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Data.Objects;
using Course.Models;

namespace Course.DAO
{
    public class AdminDAO
    {
        /// <summary>
        /// 获取一条管理员信息
        /// </summary>
        /// <param name="name"></param>
        /// <returns></returns>
        public Admin GetOne(string name)
        {
            var query = DBHelper.Entity.Admins.SingleOrDefault(a => a.Aname == name);
            return query;
        }
    }
}